
function sendLocation(x, y, r){
    var location = new proto.protobuf.C2SLocation()
    location.setX(x)
    location.setY(y)
    location.setR(r)
    onSend(location, 1);
}


function getLocation(data){
    var location = new proto.protobuf.S2CLocation.deserializeBinary(data)
    if (location.getAccount() != account){
        Ship2.prototype.update = function(ctx) {
            this.x = location.getX()
            this.y = location.getY()
            this.rotation = location.getR()
        };
    }
}